#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;

void solve() {
    int n;
    cin >> n;
    vector<int> a(n);
    for(int i = 0; i < n; i++) cin >> a[i];
    map<int, int> mp;
    for(auto x : a) {
        if(mp[x]) {
            cout << "NO\n";
            return;
        }
        mp[x]++;
    }
    cout << "YES\n";
}

int main() {
    int t;
    cin >> t;
    while(t--) solve();
    return 0;
}